% TEMPLATE FOR STANDARD QUIZ
% by laura
\documentclass[14pt,epsfig]{article}

\usepackage{graphicx}
\usepackage{amsmath}
\usepackage{amssymb}
\usepackage{hyperref}
%testpoints.tex
\oddsidemargin=0in
\evensidemargin=0in
\textwidth=6.3in
\topmargin=-0.5in
\textheight=9in
\parindent=0in
\pagestyle{empty}

\newcounter{problemnum}
\renewcommand{\theproblemnum}{\arabic{problemnum}}
\newcounter{partnum}[problemnum]
\renewcommand{\thepartnum}{\alph{partnum}}
\newcounter{totalpoints}
\newcounter{curprobpts}	
\newcounter{totalparts}
\newcounter{pagepoints}
\newenvironment{problem}[1]{
\refstepcounter{problemnum}
\vspace{0.15in} \par
\setcounter{curprobpts}{#1} \setcounter{totalparts}{0}
{\Large \bf \theproblemnum. \normalsize ({\it \arabic{curprobpts} point\null\ifnum \value{curprobpts} = 1\else s\fi}\/)}
}{\ifnum \value{totalparts} = 0
	\addtocounter{totalpoints}{\value{curprobpts}}	% Add pts to total.
	\addtocounter{pagepoints}{\value{curprobpts}}
	\else \ifnum \value{totalparts} = \value{curprobpts}
	\else \typeout{}
	\typeout{!!!!!!!   POINT ACCOUNTING ERROR   !!!!!!!!}
	\typeout{PROBLEM [\theproblemnum] WAS ALLOCATED \arabic{curprobpts} POINTS,}
	\typeout{BUT CONTAINS PARTS TOTALLING \arabic{totalparts} POINTS!}
	\typeout{}
	\fi
\fi
}
\newcommand{\newpart}[1]
{
\refstepcounter{partnum}
\hspace{0.25in}	
\ifnum #1 > 0
	\makebox[0.5in][l]{{\bf \thepartnum.} {\bf ({\it #1 pt\ifnum #1 = 1\else s\fi\/}) \,\,}}
\else
	\makebox[0.25in][l]{({\bf \thepartnum})}
\fi
\hspace{0.1in}	
\addtocounter{totalparts}{#1}
\addtocounter{pagepoints}{#1}
\addtocounter{totalpoints}{#1}
}
\newcommand{\skipproblem}[1]{\addtocounter{problemnum}{#1}}

\newcommand{\showpoints}
{
\typeout{}  
\typeout{====> A TOTAL OF \arabic{totalpoints} POINTS WERE READ.}
\typeout{}
}
%%%%%end testpoints.tex
%\input{testpoints}

\begin{document}


%%%(change to appropriate class and semester)
MATH 2222H{\&}J Spring 2016

%%%(change to appropriate quiz type and date)
Quiz 1 \hspace{1.9in} {SOLUTION} \vspace{2pc}

%%%(modify rules, time, points as appropriate)

\vspace{2pc}

\begin{problem}{1}
What does the equation $x^2+(y-1)^2=4$ describe in $\mathbb{R}^2$? \\
\textit{Solution:} Recall that the equation $(x-a)^2+(y-b)^2=r^2$ describes the circle of radius $r$ centered at $(a,b)$. Therefore the equation in question describes the \href{http://www.wolframalpha.com/input/?i=circle+of+radius+2+centered+at+%280%2C1%29}{circle of radius $2$ centered at $(0,1)$}. 
\end{problem}

\begin{problem}{2}
Let $\vec{a}=<3,1,2>$ and $\vec{b}=<-1,4,3>$. Calculate $\lVert \vec{b} \rVert$, $\vec{a}-7\vec{b}$, and $\lVert \vec{a}-7\vec{b} \rVert$. \\
\textit{Solution:} First \href{http://www.wolframalpha.com/input/?i=||%3C-1%2C4%2C3%3E||}{compute}
$$\lVert \vec{b} \rVert = \sqrt{(-1)^2+4^2+3^2}=\sqrt{1+16+9} = \sqrt{26}.$$
Now \href{http://www.wolframalpha.com/input/?i=%3C3%2C1%2C2%3E-7*%3C-1%2C4%2C3%3E}{compute}
$$\begin{array}{ll}
\vec{a}-7\vec{b} &= <3,1,2> - 7<-1,4,3> \\
&= <3,1,2> + <7,-28,-21> \\
&= <3+7, 1-28, 2-21> \\
&=<10,-27,-19>.
\end{array}$$
Finally \href{http://www.wolframalpha.com/input/?i=||%3C10%2C-27%2C-19%3E||}{compute}
$$\lVert \vec{a}-7\vec{b} \rVert=\lVert <10,-27,-19> \rVert = \sqrt{10^2+(-27)^2+(-19)^2}=\sqrt{1190}.$$
\end{problem}

\begin{problem}{2}
Let $P=(3,4,-1)$ and $Q=(2,2,1)$ be points in $\mathbb{R}^3$. Find the vectors $\overrightarrow{PQ}$ (the vector from $P$ to $Q$) and $\overrightarrow{QP}$ (the vector from $Q$ to $P$). What relationship does $\overrightarrow{PQ}$ have to $\overrightarrow{QP}$? \\
\textit{Solution:} First \href{http://www.wolframalpha.com/input/?i=%3C2%2C2%2C1%3E-%3C3%2C4%2C-1%3E}{compute}
$$\overrightarrow{PQ}=Q-P=<2,2,1>-<3,4,-1>=<2-3,2-4,1-(-1)>=<-1,-2,2>.$$
Now \href{http://www.wolframalpha.com/input/?i=%3C3%2C4%2C-1%3E-%3C2%2C2%2C1%3E}{compute}
$$\overrightarrow{QP}=P-Q=<3,4,-1>-<2,2,1>=<3-2,4-2,-1-1>=<1,2,-2>.$$
We see that $\overrightarrow{PQ}=-\overrightarrow{QP}$, i.e., it is the same vector with opposite direction.
\end{problem}

\showpoints
\end{document}